CC = gcc
CCOPTS = -c -g -Wall
LINKOPTS = -g

all: sim

sim: simulator.o sched.o
	$(CC) $(LINKOPTS) -o $@ $^

simulator.o: simulator.c sched.o mp5.h
	$(CC) $(CCOPTS) -o $@ simulator.c

sched.o: sched.c mp5.h
	$(CC) $(CCOPTS) -o $@ sched.c

clean:
	rm -rf *.o sim sim.exe *~
